﻿Imports DataDynamics.ActiveReports
Imports DataDynamics.ActiveReports.Document
Imports System.Drawing
Imports Touto.Base.ComUtility

Public Class RP0040P03

#Region "変数"

    ''' <summary>
    ''' ページフラグ
    ''' </summary>
    ''' <remarks></remarks>
    Private blnNewPage As Boolean = False

    Dim rowcounts As Integer = -1

    Dim rows As Integer = 0

#End Region

    Private Sub RP0040P03_PageStart(sender As Object, e As System.EventArgs) Handles Me.PageStart
        'If rows > rowcounts - 39 Then
        '    PageFooter.Height = 1.442 / 2.54
        'Else
        '    PageFooter.Height = 0.962 / 2.54
        'End If
    End Sub

    Private Sub RP0040P03_ReportStart(sender As Object, e As System.EventArgs) Handles Me.ReportStart
        Dim dt As DataTable
        dt = Me.DataSource
        rowcounts = dt.Rows.Count
        AllTotal1.Text = 0
        AllTotal2.Text = 0
        Alltotal3.Text = 0

    End Sub

    Private Sub GroupHeader1_Format(sender As System.Object, e As System.EventArgs) Handles GroupHeader1.Format
        blnNewPage = True

    End Sub

    Private Sub GroupHeader2_Format(sender As System.Object, e As System.EventArgs) Handles GroupHeader2.Format
        If blnNewPage = True Then
            GroupHeader2.Height = 0
            blnNewPage = False
        End If
    End Sub

    Private Sub RP0040P03_FetchData(sender As Object, eArgs As DataDynamics.ActiveReports.ActiveReport.FetchEventArgs) Handles Me.FetchData
        rows += 1
    End Sub

End Class
